This repository was archived by the owner on Sep 9, 2025. It is now read-only.
Draft
Conversation
How to use the Graphite Merge QueueAdd the label merge-ready to this PR to add it to the merge queue. You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi! Regarding issue #342.
The conjecture 8.4 in this paper seems to refer to the security guarantees of applying theorems 1.2, 1.4 and 1.6 with some margin defined by parameter
η > 0. But the error referred in the conjecture doesn't seem to be applicable to FRI for estimating the number of queries as stated in the issue descriptionStill, I have found something insightful that might be worth to consider, the paper states that you can calculate the number of queries like:
when
(which seems to be the case in most configurations)
See teorem 8.3 discussion (https://eprint.iacr.org/2020/654.pdf)
Which brings a reduction of around 33% in the number of queries! So I went ahead and implemented the
fri_conjectureflag (this name maybe doesn't make sense anymore though)I have created a couple of tests to verify that this implementation has reasonable results, and seems to be the case :)
test_calculate_n_test_queries_fri_conjecture: this test is essentially the same as the existing one but applying the formulatest_n_test_queries_fri_conjecture_66_security_bits: this one is based on this paper, I wanted to replicate the cases they have tested to compare against this:test_n_test_queries_fri_conjecture_128_security_bits: also based on this paper:Note:
q >> n^2is an ambiguous criteria to implement. So I definedFRI_CONJECTURE_SAFETY_FACTOR = 10constant, which gives you the factor of difference between the field sizeqand the blocklengthn, I arbitrarily definedq >= 10*q^2as the limit of applicability (up to discussion)I haven't implemented the Params struct putting all the parameters together just to make it easier to review, though the only critical file to review is
crates/core/src/protocols/fri/common.rs.I might be wrong in some of the points I have made here, I studied the paper for a few days but still some parts are tricky to understand to me, anyways I'm open to discussion if you need any clarification :)